<?php

namespace common\entities\myhtsq;

use Yii;

/**
 * This is the model class for table "myscrm_contract_category".
 *
 * @property string $category_id
 * @property string $category_name
 * @property string $created_on
 * @property string $created_by
 * @property string $modified_on
 * @property string $modified_by
 */
class ContractCategoryEntity extends \common\entities\ConfigEntity
{
    /**
     * @inheritdoc
     */
    public static function tableName()
    {
        return 'myscrm_contract_category';
    }

    /**
     * @inheritdoc
     */
    public function rules()
    {
        return [
            [['category_id'], 'required'],
            [['created_on', 'modified_on'], 'safe'],
            [['category_id', 'created_by', 'modified_by'], 'string', 'max' => 36],
            [['category_name'], 'string', 'max' => 50]
        ];
    }

    /**
     * @inheritdoc
     */
    public function attributeLabels()
    {
        return [
            'category_id' => '类别ID',
            'category_name' => '类别名称',
            'created_on' => '创建时间',
            'created_by' => '创建人',
            'modified_on' => '修改时间',
            'modified_by' => '修改人',
        ];
    }
}
